<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>confirm</title>
    <script src="../jquery-1.7.2.js"></script>
</head>
<body>
<script>
    $(function(){
       var a =  confirm('are you ok?');
        if(a== true ){
            alert('lair');
        }else {
            return false
        }
    })
</script>
</body>
</html>